package entry;

public class Disc {
    private String name;
    private int price;
    private String date;
    private int key;
    private boolean ZT;

    public String getName() {
        return name;
    }

    @Override
    public String toString() {
        String temp;
        if (ZT){
            temp="可出租";
        }else {
            temp="不可出租";
        }
        return "碟片信息-->[" +
                "碟片名称-->《" + name + "》" +
                ", 碟片价格-->" + price +"元/天"+
                ", 出租日期-->'" + date + '\'' +
                ", 租出次数-->" + key +
                ", 当前状态-->" + temp +
                ']';
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getPrice() {
        return price;
    }

    public void setPrice(int price) {
        this.price = price;
    }

    public String getDate() {
        return date;
    }

    public void setDate(String date) {
        this.date = date;
    }

    public int getKey() {
        return key;
    }

    public void setKey(int key) {
        this.key = key;
    }

    public boolean isZT() {
        return ZT;
    }

    public void setZT(boolean ZT) {
        this.ZT = ZT;
    }

    public Disc() {
    }

    public Disc(String name, int price, String date, int key, boolean ZT) {
        this.name = name;
        this.price = price;
        this.date = date;
        this.key = key;
        this.ZT = ZT;
    }
}
